Traditionally, hierarchical data relationships, such as trees or directory/folder-type data structures or organizing schemes, are commonly defined or implemented in parent-child type data tables. A traditional hierarchical data relationship is depicted in FIG. 1. Hierarchical tree data relationship 1, having root node 11, and tree relationship 2 having root node 12, correspond to the hierarchical relationship data in table 3. In such tables, the hierarchical relationships 1, 2 are broken down as a collection of parent-child relationships or pointers, where the hierarchical container or tree identifier 1, 2, is indicated in column 4, and the parent (column 5) and child (column 6) relationships making up the hierarchical relationships are set out for each tree 1, 2. For example, in hierarchical container 2, with root node 12 having child node 22, the child relationships 23 of node 22 are child node 32 (the relationship being stored in row 42), and child node 33 (the relationship stored in row 43).
Such tabular implementations have some disadvantages with respect to the storage of such data structures, and particularly in the case of database storage of the hierarchical data structure. For example, if someone desires that the hierarchical data structure be reconstructed from a database stored in the form depicted in table 3, O(n) queries will be required, where n is the number of nodes in the tree. This linear reconstruction time may be associated with significant degradation in performance for commonly-encountered real-world large values n.
Additionally, this parent-child data table 3 for a hierarchical data structure leaves the data structure unsuitable for embedding in an object, because the parent-child relationships that make up the data structure 1, 2 are stored in a table 3 that is external to the head or root node 101, 102, pointer, or other identifying characteristic of a given data structure 1, 2 or instance thereof.
Versioning of data, such as a hierarchical data structure, may include the naming and cataloging of discrete or unique states of an object or data structure such as a hierarchical data structure. As a consequence of the storage aspects of hierarchical containers discussed above, including the complexity and volume of required storage, versioning of hierarchical data structures is generally inefficient. As these data structures change, it is typically necessary to maintain the entire historical data structure in order to show past versions of the data structure being examined. Thus, a great deal of storage is required to maintain historical information about these data structures.
There is a need, therefore, for an improved method, article of manufacture, and apparatus for the organization of data in data systems, including for hierarchical data structures, and for making modifications to the data stored in data systems.